package org.minproject.my_library_back.service;

import org.minproject.my_library_back.common.CommonResponse;
import org.minproject.my_library_back.domain.Borrow;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
* @author Lenovo
* @description 针对表【borrow】的数据库操作Service
* @createDate 2024-11-21 09:11:46
*/
public interface BorrowService extends IService<Borrow> {
    CommonResponse<List<Borrow>> getBorrows() throws Exception;
    CommonResponse<List<Borrow>> getBorrowsByUserid(int userid) throws Exception;
    CommonResponse<Borrow> addBorrow(Borrow borrow) throws Exception;
    CommonResponse<Borrow> deleteBorrow(Borrow borrow) throws Exception;
    CommonResponse<Borrow> returnBorrow(Borrow borrow) throws Exception;
}
